<?xml version="1.0" encoding="UTF-8"?>

<!DOCTYPE hibernate-mapping PUBLIC
    "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
    "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">

<hibernate-mapping>
    <class name="cn.firstsoft.modules.portlet.domain.PortletNew" table="portlet_new">
      <id name="id" type="integer">
            <column name="id" />
            <generator class="native" >
				         <param name="sequence">PORTLET_NEW_ID_SEQ</param>
            </generator>
        </id>
        <property name="name" type="string">
               <column name="name" length="200" />
        </property>
        <property name="code" type="string">
               <column name="code" length="100" />
        </property>
         <property name="status" type="integer">
               <column name="status" />
        </property>
           <property name="postionY" type="integer">
               <column name="postion_y" />
        </property>
        <property name="postionX" type="integer">
               <column name="postion_x"/>
        </property>
        <property name="descn" type="string">
        	<column name="descn" length="500"/>
        </property>
        
         <property name="newOrSet" type="integer">
               <column name="new_or_set"/>
        </property>
        
        <property name="tittlePic" type="string">
               <column name="tittle_pic"/>
        </property>

        <set name="portletNewTabSet" lazy="true" cascade="all" batch-size="5" inverse="true">
            <key>
             <column name="portlet_new_id" not-null="true"/>
            </key>
            <one-to-many class="cn.firstsoft.modules.portlet.domain.PortletNewTab"/>
        </set>
        
        <set name="portletNewTabPersonalSet" lazy="true" cascade="all" batch-size="5" inverse="true">
            <key>
             <column name="portlet_new_id" not-null="true"/>
            </key>
            <one-to-many class="cn.firstsoft.modules.portlet.domain.PortletNewTabPersonal"/>
        </set>
    </class>
</hibernate-mapping>
